//
//  TherapyDetailTableViewCell.m
//  Happy Kitchen
//
//  Created by mac_chen on 15/3/7.
//  Copyright (c) 2015年 mac_chen. All rights reserved.
//

#import "TherapyDetailTableViewCell.h"

@implementation TherapyDetailTableViewCell

- (instancetype)initWithStyle:(UITableViewCellStyle)style reuseIdentifier:(NSString *)reuseIdentifier
{
    self = [super initWithStyle:style reuseIdentifier:reuseIdentifier];
    if (self) {
        [self createSub];
    }
    return self;
}
- (void)createSub
{
    //美食图片
    self.imageNameImageView = [[UIImageView alloc] initWithFrame:CGRectMake(15, 13, 35, 35)];
    self.imageNameImageView.userInteractionEnabled = YES;
    [self.contentView addSubview:self.imageNameImageView];
    //美食的名字
    self.diseaseName = [[UILabel alloc] initWithFrame:CGRectMake(80, 25, 200, 20)];
    [self.contentView addSubview:self.diseaseName];
    
}

//自定义方法,赋值
- (void)setTherapyDetail:(TherapyDetail *)therapyDetail
{
    self.diseaseName.text = therapyDetail.diseaseName;
}

- (void)awakeFromNib {
    // Initialization code
}

- (void)setSelected:(BOOL)selected animated:(BOOL)animated {
    [super setSelected:selected animated:animated];

    // Configure the view for the selected state
}

@end
